Release 10.1A: OpenEdge Development:
Debugging and Troubleshooting
Variables pane
The variables pane provides access to the variables associated with the current procedure. The Debugger organizes and displays variable data on tabs named for the following categories:
Select a tab to display all variables in that category. Each tab in the variables pane has a context (right-click) menu containing the following options: Copy, Cut, Paste, Dataview (displays attribute or field information for the selected variable in the Dataview dialog box), and Add Watch (adds the selected variable to the watches pane). For more information, see the "Dataview dialog box" section and the "Add Watch dialog box" section.
Double-clicking on a cell containing the value of a variable makes the value editable. You can modify the value by entering a different value and pressing the ENTER key or clicking out of the cell. Pressing the ESC key when editing a value restores the current value and cancels the editing operation.
The Debugger displays raw (unformatted) variable data. For example, a decimal value of 1,234.56 appears as 1234.56; 1.00 appears as 1. Do not use formatting characters when entering variable values. Dynamic temp-table and dataset-related objects appear in the variables tab as handle variables.
Viewing Arrays
Array parameters and array variables can appear on the respective tab in the variables pane. The Debugger displays the name of the array, the number of extents (in brackets), and the data type (for example,
DaysInMonth[12]INTEGER). You can view the value of an array element as a watch (DaysInMonth[3]) or view the entire contents of the array in the Array tab of the Dataview dialog box.If an array has an indeterminate extent (that is, it was declared as
EXTENTwith no limitingexp), the Debugger displays the current value of theEXTENTfunction for the array. Before the array’s size is determined, the extent of the array is unknown, so the Debugger displays[?]in the Value column for the variable or parameter. When the array is populated or received as a parameter from an array with a known size, the extent is set. For example, if a calling procedure declares the array asEXTENT5and passes it to a procedure where the array was declared to have an indeterminate extent, the receiving array is set to an extent of 5, once the procedure is called. At this point, the Debugger displays[5]as the value, and there is no indication the array originally was declared as having an indeterminate extent.Viewing objects of data type BLOB
4GL programmers use the
BLOBdata type to store arbitrary binary data. ABLOBis similar to aMEMPTR, and the Debugger handlesBLOBs in much the same way asMEMPTRs. Specifically, the Debugger displays the total length of theBLOBin parentheses, followed by the first 256 bytes (or fewer, if theBLOBis smaller than 256 bytes) of theBLOBin hexadecimal, followed by an ellipsis indicating there is more data that is not shown, if theBLOBcontains more than 256 bytes. For example:
You cannot edit
BLOBvalues; the Value cell is read-only.Due to its small size, the Value cell shows only a small part of the
BLOBdata. To see the full 256 bytes ofBLOBdata, view theBLOBin the Value tab of the Dataview dialog box.Viewing objects of data types CLOB and LONGCHAR
4GL programmers use
CLOBandLONGCHARdata types to store large amounts of text data. The Debugger displays the total length of theCLOBorLONGCHARin parentheses, followed by the first 256 characters (or fewer, if theCLOBorLONGCHARis smaller than 256 characters) of theCLOBorLONGCHARas a quoted string, followed by an ellipsis indicating there is more data that is not shown, if theCLOBorLONGCHARcontains more than 256 characters.You cannot edit
CLOBandLONGCHARvalues; the Value cell is read-only.Due to its small size, the Value cell shows only a small part of
CLOBandLONGCHARdata. To see the full 256 characters of data, view theCLOBorLONGCHARin the Value tab of the Dataview dialog box.Viewing objects of data type DATETIME
The
DATETIMEdata type is a timestamp consisting of a date (same as the 4GLDATEdata type) and a time (since midnight). TheDATETIME-TZdata type extends this, by including time zone information. The Debugger displays values of either type anywhere they are used: program variables, parameters, buffer fields, and watches. You can assign a new value to aDATETIMEorDATETIME-TZobject by editing its value. The Debugger shows unformatted data; for example, it displays the milliseconds portion of aDATETIMEorDATETIME-TZfield, even if the field's format does not include milliseconds.The Debugger displays
DATETIMEandDATETIME-TZfields in OpenEdge’s currentSESSION:DATE-FORMATsetting (dmy,mdy,ydm, orymd) and interprets assignments the same way. That is, to assign aDATETIMEorDATETIME-TZfield in the Debugger, use the format dictated by OpenEdge’sDATE-FORMATsetting.Viewing objects of datatype Progress.Lang.ProObject
The
Progress.Lang.ProObjectdatatype is a built-in class definition that provides a common set of methods for an object. The Debugger displays an integer value for the reference followed by the name of the class the variable references. For example “1101 (Class MyClass)”.Viewing data members of a class
The data members of a class may be
Note:PUBLIC,PRIVATE(the default), orPROTECTED.PUBLICandPROTECTEDmembers are accessible from both the superclass and subclasses. The Debugger displaysPUBLICandPROTECTEDmembers in the Variables pane for both the superclass and subclasses.PRIVATEmembers appear only in the class that defines them.PRIVATEmembers only appear when the class is the current execution frame on the 4GL stack.PUBLICandPROTECTEDmembers appear from any execution frame that references them.Viewing ProDataSet objects
The ProDataSet object is a collection of temp-table buffer objects and relations among the temp-table objects. A ProDataSet consists of three object types—
DATASET,DATA-RELATION, andDATA-SOURCE—each with several attributes and methods. The Datasets tab contains the names of all static ProDataSet-related objects declared in the current procedure context. You can right-click on any listed object and select Dataview from the pop-up menu, to see the object’s attributes.
|
Copyright © 2005 Progress Software Corporation www.progress.com Voice: (781) 280-4000 Fax: (781) 280-4095 |